package org.nobody.mallb2c.mallproduct.service;

import com.baomidou.mybatisplus.extension.service.IService;
import org.nobody.common.utils.PageUtils;
import org.nobody.mallb2c.mallproduct.entity.CategoryEntity;
import org.nobody.mallb2c.mallproduct.vo.Catelog2Vo;

import java.util.List;
import java.util.Map;

/**
 * 商品三级分类
 *
 * @author fancier
 * @email fancier2093@gmail.com
 * @date 2020-07-30 16:25:27
 */
public interface CategoryService extends IService<CategoryEntity> {

  PageUtils queryPage(Map<String, Object> params);

  List<CategoryEntity> listWithTree();

  void removeMenuByIds(List<Long> asList);

  Long[] findCatelogPath(Long catelogId);

  void updateCascade(CategoryEntity category);

  List<CategoryEntity> getLevel1Categorys();

  Map<String, List<Catelog2Vo>> getCatalogJsonFromDb();

  Map<String, List<Catelog2Vo>> getCatalogJsonFromDbWithLocalLock();

  Map<String, List<Catelog2Vo>> getCatalogJsonFromDbWithRedissonLock();

  Map<String, List<Catelog2Vo>> getCatalogJsonFromDbWithDCSLock();

  Map<String, List<Catelog2Vo>> getCatalogJson();
}

